/*
package top.fengyulou.xiaofeng.controller;

import org.springframework.boot.web.servlet.error.ErrorController;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import top.fengyulou.xiaofeng.common.WebUtils;

import javax.servlet.http.HttpServletRequest;


@Controller
class MainsiteErrorController implements ErrorController {

    @RequestMapping("/error")
    public String handleError(HttpServletRequest request) {
        //获取statusCode:401,404,500
//        Integer statusCode = (Integer) request.getAttribute("javax.servlet.error.status_code");
        return WebUtils.redirect("/");
    }

    @Override
    public String getErrorPath() {
        return "/error";
    }
}*/
